﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Libs.Content;

public partial class Controls_Right_Photo : System.Web.UI.UserControl
{
    protected void Page_Load(object sender, EventArgs e)
    {
        // 52 là ID của chuyên mục ảnh

        List<NewsWeb> list;
        NewsWeb _NewsWeb = new NewsWeb();

        list = _NewsWeb.GetList(52, 0, 5);
        _NewsWeb = list[0];
        hlTopImg.HRef = hlTop.HRef = list[0].Url;
        hlTop.InnerText = list[0].Title;
        imgTop.ImageUrl = AppUtils.ImageUrl(_NewsWeb.ImageUrl, "256", "192");
        rptPhoto.DataSource = list;
        rptPhoto.DataBind();
    }
}